package com.etennis.controller;

import com.etennis.pojos.ResponseResult;
import com.etennis.pojos.vo.web.PublicityVO;
import com.etennis.service.INoticeService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.ArrayList;
import java.util.List;

@RestController
@RequestMapping("/app/publicity")
@Slf4j
@Api(tags = "用户端-公示接口")
public class PublicityController {
    @Autowired
    INoticeService iNoticeService;

    @GetMapping
    @ApiOperation("公示板")
    public ResponseResult<List<PublicityVO>> publicity(){
        List<PublicityVO> list=iNoticeService.publicity();
        return ResponseResult.okResult(list);
    }
}
